{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "humanitarian-toronto",
   "metadata": {},
   "source": [
    "https://leetcode.com/problems/kth-largest-element-in-an-array\n",
    "\n",
    "\n",
    "Runtime: 8 ms, faster than 83.80% of C++ online submissions for Kth Largest Element in an Array.\n",
    "Memory Usage: 9.8 MB, less than 97.33% of C++ online submissions for Kth Largest Element in an Array.\n",
    "\n",
    "\n",
    "```cpp\n",
    "#include <vector>\n",
    "#include <algorithm>\n",
    "#include <string>\n",
    "#include <iostream>\n",
    "\n",
    "using namespace std;\n",
    "\n",
    "class Solution {\n",
    "public:\n",
    "    int findKthLargest(vector<int>& nums, int k) {\n",
    "        sort(nums.begin(), nums.end());\n",
    "        return nums[nums.size()-k];\n",
    "    }\n",
    "};\n",
    "```"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "infectious-springfield",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "C++17",
   "language": "C++17",
   "name": "xcpp17"
  },
  "language_info": {
   "codemirror_mode": "text/x-c++src",
   "file_extension": ".cpp",
   "mimetype": "text/x-c++src",
   "name": "c++",
   "version": "17"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
